package com.tcfvic.client.pojos;
// Generated 29/03/2010 9:10:01 PM by Hibernate Tools 3.1.0.beta4

import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;


/**
 * Course generated by hbm2java
 */
@Entity
@Table(name="course"
    
, uniqueConstraints = {  }
)

public class Course  implements java.io.Serializable {


    // Fields    

     private int id;
     private Courselevel courselevel;
     private Rto rto;
     private String name;
     private Double cost;
     private String courseType;
     private String industry;
     private String category;
     private String level;
     private String length;
     private String fulltimeparttime;
     private Integer hoursperweek;
     private String notes;
     private String display;
     private Set<Personcourse> personcourses = new HashSet<Personcourse>(0);


    // Constructors

    /** default constructor */
    public Course() {
    }

	/** minimal constructor */
    public Course(int id) {
        this.id = id;
    }
    
    /** full constructor */
    public Course(int id, Courselevel courselevel, Rto rto, String name, Double cost, String courseType, String industry, String category, String level, String length, String fulltimeparttime, Integer hoursperweek, String notes, String display, Set<Personcourse> personcourses) {
        this.id = id;
        this.courselevel = courselevel;
        this.rto = rto;
        this.name = name;
        this.cost = cost;
        this.courseType = courseType;
        this.industry = industry;
        this.category = category;
        this.level = level;
        this.length = length;
        this.fulltimeparttime = fulltimeparttime;
        this.hoursperweek = hoursperweek;
        this.notes = notes;
        this.display = display;
        this.personcourses = personcourses;
    }
    

   
    // Property accessors
    @Id
    @Column(name="id", unique=true, nullable=false, insertable=true, updatable=true)
@GeneratedValue(strategy=GenerationType.AUTO)

    public int getId() {
        return this.id;
    }
    
    public void setId(int id) {
        this.id = id;
    }
    @ManyToOne(cascade={},
        fetch=FetchType.LAZY)
    
        @JoinColumn(name="courseLevel_id", unique=false, nullable=true, insertable=true, updatable=true)

    public Courselevel getCourselevel() {
        return this.courselevel;
    }
    
    public void setCourselevel(Courselevel courselevel) {
        this.courselevel = courselevel;
    }
    @ManyToOne(cascade={},
        fetch=FetchType.LAZY)
    
        @JoinColumn(name="RTO_id", unique=false, nullable=true, insertable=true, updatable=true)

    public Rto getRto() {
        return this.rto;
    }
    
    public void setRto(Rto rto) {
        this.rto = rto;
    }
    @Column(name="name", unique=false, nullable=true, insertable=true, updatable=true, length=400)

    public String getName() {
        return this.name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    @Column(name="cost", unique=false, nullable=true, insertable=true, updatable=true, precision=22, scale=0)

    public Double getCost() {
        return this.cost;
    }
    
    public void setCost(Double cost) {
        this.cost = cost;
    }
    @Column(name="courseType", unique=false, nullable=true, insertable=true, updatable=true, length=200)

    public String getCourseType() {
        return this.courseType;
    }
    
    public void setCourseType(String courseType) {
        this.courseType = courseType;
    }
    @Column(name="industry", unique=false, nullable=true, insertable=true, updatable=true, length=200)

    public String getIndustry() {
        return this.industry;
    }
    
    public void setIndustry(String industry) {
        this.industry = industry;
    }
    @Column(name="category", unique=false, nullable=true, insertable=true, updatable=true, length=100)

    public String getCategory() {
        return this.category;
    }
    
    public void setCategory(String category) {
        this.category = category;
    }
    @Column(name="level", unique=false, nullable=true, insertable=true, updatable=true, length=45)

    public String getLevel() {
        return this.level;
    }
    
    public void setLevel(String level) {
        this.level = level;
    }
    @Column(name="length", unique=false, nullable=true, insertable=true, updatable=true, length=45)

    public String getLength() {
        return this.length;
    }
    
    public void setLength(String length) {
        this.length = length;
    }
    @Column(name="fulltimeparttime", unique=false, nullable=true, insertable=true, updatable=true, length=45)

    public String getFulltimeparttime() {
        return this.fulltimeparttime;
    }
    
    public void setFulltimeparttime(String fulltimeparttime) {
        this.fulltimeparttime = fulltimeparttime;
    }
    @Column(name="hoursperweek", unique=false, nullable=true, insertable=true, updatable=true)

    public Integer getHoursperweek() {
        return this.hoursperweek;
    }
    
    public void setHoursperweek(Integer hoursperweek) {
        this.hoursperweek = hoursperweek;
    }
    @Column(name="notes", unique=false, nullable=true, insertable=true, updatable=true, length=4000)

    public String getNotes() {
        return this.notes;
    }
    
    public void setNotes(String notes) {
        this.notes = notes;
    }
    @OneToMany(cascade={CascadeType.ALL}, fetch=FetchType.LAZY, mappedBy="course")

    public Set<Personcourse> getPersoncourses() {
        return this.personcourses;
    }
    
    public void setPersoncourses(Set<Personcourse> personcourses) {
        this.personcourses = personcourses;
    }
	public void setDisplay(String display) {
		this.display = display;
	}

    @Column(name="display", unique=false, nullable=true, insertable=true, updatable=true, length=100)
	public String getDisplay() {
		return display;
	}

}
